//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package org.come.control;

import org.come.Frame.NPCJfram;
import org.come.action.FromServerAction;
import org.come.bean.NpcInfoBean;
import org.come.bean.NpcMenuBean;
import org.come.bean.NpcSureMenuBean;
import org.come.until.ControlNpcXmlUntil;
import org.come.until.UserMessUntil;

public class NPCDialogControl implements FromServerAction {
    public NPCDialogControl() {
    }

    @Override
    public void controlMessFromServer(String mes, String type) {
        NpcInfoBean infoBean = UserMessUntil.getnpc(mes);
        if (infoBean != null) {
            ControlNpcXmlUntil.setNpcmenubean(new NpcMenuBean());
            ControlNpcXmlUntil.setSureBean(new NpcSureMenuBean());
            ControlNpcXmlUntil.setType(infoBean.getNpctable().getNpctype());

            try {
                ControlNpcXmlUntil.GetXmlPath("npcMenu.xml");
            } catch (Exception var5) {
                var5.printStackTrace();
            }

            NPCJfram.getNpcJfram().getNpcjpanel().npc(ControlNpcXmlUntil.getNpcmenubean(), infoBean);
        }
    }
}
